package com.tiancheng.trade.payment.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.tiancheng.trade.commom.core.enums.PaymentChannelEnum;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDate;
import java.util.Date;

/**
 * 清分文件表
 *
 * @author kellen
 * @date 2024-12-09 16:45
 */
@TableName(value = "settle_file")
@Data
public class SettleFile implements Serializable {
    // 主键
    @TableId(type = IdType.ASSIGN_ID)
    private Long id;
    /**
     * 商户集团编号
     */
    private String groupCode;

    /**
     * 渠道：cmb=计平；ums=银联商务
     *
     * @see PaymentChannelEnum
     */
    private String channel;

    /**
     * 划付-文件名
     */
    private String apprFileName;

    /**
     * 划付-总笔数
     */
    private Integer apprTotalNum;

    /**
     * 划付-总金额
     */
    private Long apprTotalAmount;

    /**
     * 划付-成功笔数
     */
    private Integer apprSuccessNum;

    /**
     * 划付-成功金额
     */
    private Long apprSuccessAmount;

    /**
     * 划付-部分成功笔数
     */
    private Integer apprSuccessPart;

    /**
     * 划付-部分成功金额
     */
    private Long apprSuccessPartAmount;

    /**
     * 划付-失败笔数
     */
    private Integer apprFailNum;

    /**
     * 划付-失败金额
     */
    private Long apprFailAmount;

    /**
     * 划付-部分付失败金额
     */
    private Long apprFailPartAmount;

    /**
     * 划付-实际成功金额，扣除清算费用后的实际到帐金额
     */
    private Long apprActualAmount;

    /**
     * 划付-手续费金额
     */
    private Long apprServiceFee;

    /**
     * 划付-处理中笔数
     */
    private Integer apprHandleNum;

    /**
     * 划付-处理中金额
     */
    private Long apprHandleAmount;

    /**
     * 分账-文件名
     */
    private String distFileName;

    /**
     * 分账-总笔数
     */
    private Integer distTotalNum;

    /**
     * 分账-总金额
     */
    private Long distTotalAmount;

    /**
     * 分账-成功笔数
     */
    private Integer distSuccessNum;

    /**
     * 分账-成功金额
     */
    private Long distSuccessAmount;

    /**
     * 分账-部分成功笔数
     */
    private Integer distSuccessPart;

    /**
     * 分账-部分成功金额
     */
    private Long distSuccessPartAmount;

    /**
     * 分账-失败笔数
     */
    private Integer distFailNum;

    private Date createDate;

    private Date updateDate;

    /**
     * 划付文件下载地址
     */
    private String apprBackFileUrl;

    /**
     * 分账文件下载地址
     */
    private String distBackFileUrl;

    /**
     * 清分日期
     */
    private LocalDate clearDate;

}